package com.xuyl.entity;

import lombok.Data;

/**
 * @author nisemono
 * @date 2023-02-27 20:23
 */
@Data
public class Result {
    private Integer code;
    private boolean flag;
    private String msg;
    private Object data;


    public Result(boolean flag) {
        this.flag = flag;
    }

    public Result(boolean flag, String msg) {
        this.flag = flag;
        this.msg = msg;
    }

    public Result(boolean flag, Integer code, String msg, Object data) {
        this.code = code;
        this.flag = flag;
        this.msg = msg;
        this.data = data;
    }

    public Result(boolean flag, String msg, Object data) {
        this.flag = flag;
        this.msg = msg;
        this.data = data;
    }

    public Result(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Result(boolean flag, Integer code, String message) {
        this.code = code;
        this.flag = flag;
        this.msg = message;
    }
}
